package com.more.offer.a_jvm;

/**
 * @author pinoc
 * @date 2021/6/15
 * @description 大对象jvm分配测试 超过阈值的大对象直接分配在老年代中
 * 3145728 = 3 * _1MB = 3145728KB
 * -verbose:gc
 * -Xms20M
 * -Xmx20M
 * -Xmn10M
 * -XX:+PrintGCDetails
 * -XX:SurvivorRatio=8
 * -XX:PretenureSizeThreshold=3145728
 */
public class TestPretenureSizeThreshold {

	private static final int _1MB = 1024 * 1024;

	public static void main(String[] args) {
		byte[] allocation;
		allocation = new byte[6 * _1MB];
	}
}
